package com.rainng.coursesystem.repository;


import com.rainng.coursesystem.model.CourseResourceItem;
import com.rainng.coursesystem.model.ExamItem;
import com.rainng.coursesystem.model.HomeworkItem;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.Date;
import java.util.List;
import java.util.Optional;
import java.util.UUID;

@Repository
public interface ExamRepository extends JpaRepository<ExamItem, Long> {



    List<ExamItem> findAllByStudentId(long studentId);

    List<ExamItem> findAllByCourseId(long courseId);

    List<ExamItem> findAllByCourseIdAndStudentId(Long courseId, Long studentId);

    List<ExamItem> findAllByExamTimeAndRoomNumber(Date examTime, String roomNumber);
}
